<script  id="tmpl_new_task_in_group" type="text/x-jquery-tmpl" style="display:none;">
<tr class="rowB jsmark-${id}">
	<td><input type="checkbox" onClick="close_task(event);" class="close-checkbox" value="${id}"> ${name}
		<div class="options">
			<a href="#" class="trigger">
				<img class="icon1" src="#">
			</a>
			<div class="sliding">
				<ul>
					<li><a class="edit-task" onClick="edit_task(event);" href="#">Edit</a></li>
					<li><a href="#">Move to</a></li>
					<li><a class="delete-task" onClick="delete_task(event);" href="#">Delete</a></li>
				</ul>
			</div>
		</div>
	</td>
	<td>${assign_user_displayname}</td>
	<td>${user_displayname}</td>
	<td>${priority_label}</td>
	<td>${deadline}</td>
	<td>${status_label}</td>
</tr>	
</script>
<script  id="tmpl_edit_task" type="text/x-jquery-tmpl" style="display:none;">
<tr class="row edit-task">
	<td colspan="6">
		<form>
		<div class="wrap-edit-task">
		 	<label>
		 		<strong>Name :</strong>
		 		<input type="text" name="name" class="name" value="${name}">
		 	</label>
		 	<label>
			 	<strong>Description :</strong>
			 	<textarea name="description"></textarea>
		 	</label>
		 	<label class="quarter">
 				<strong>Deadline :</strong>
 				<input type="text" class="deadline small" name="deadline" value="${deadline}">
		 	</label>
		 	<label class="quarter">
		 		<strong>Assign to :</strong>
		 		<select name="assign_user_id">
					{{each users}}
						<option id="aui-${$value.id}" value="${$value.id}">${$value.displayname}</option>
					{{/each}}		    
		 		</select>
		 	</label>
		 	<label class="quarter">
		 		<strong>Priority :</strong>
		 		<select name="priority">
		 			<option {{if priority == <?php echo Helper_MyConst::PRIORITY_LOW?>}} selected{{/if}} value="<?php echo Helper_MyConst::PRIORITY_LOW?>">Low</option>
		 			<option {{if priority == <?php echo Helper_MyConst::PRIORITY_MEDIUM?>}} selected{{/if}} value="<?php echo Helper_MyConst::PRIORITY_MEDIUM?>">Medium</option>
		 			<option {{if priority == <?php echo Helper_MyConst::PRIORITY_HIGH?>}} selected{{/if}} value="<?php echo Helper_MyConst::PRIORITY_HIGH?>">High</option>
		 		</select>
		 	</label>
		 	<label class="quarter">
		 		<button name="save" class="save">Save</button>
		 		<a class="cancel" href="#">Cancel	</a>
		 	</label>
			<input type="hidden" name="id" value="${id}">
 		</div>
		</form>
	</td>
</tr>
</script>
<script id="tmpl_new_group_task" type="text/x-jquery-tmpl" style="display:none;">
<div class="list ${id}">
	<a class="open-closed active" href="#" onClick="hide_show_group(event)"> Open/Closed </a>
	<h8>${name}</h8>
	<div class="list-main-body">
		<table class="list ${id} box-skin" >
			<tr class="rowA">
				<td><b>Tasks</b></td>
				<td><b>Assign to</b></td>
				<td><b>Assigned from</b></td>
				<td><b>Priority</b></td>
				<td><b>Deadline</b></td>
				<td><b>Status</b></td>
			</tr>
			<tr class="row edit-task show" style="display:none">
				<td colspan="6">
					<form method="post" accept-charset="utf-8" id="add-task-form">
						<div class="wrap-edit-task">
		 					<label>
		 						<strong>Title :</strong>
		 						<input type="text" name="name" value="">
		 					</label>
		 					<label>
		 						<strong>Description :</strong>
		 						<textarea name="decription"></textarea>
		 					</label>
		 					<div style="width:100%">
		 					<label class="quarter">
		 						<strong>Deadline :</strong>
		 						<input type="text" class="deadline small" name="deadline" value="">
		 					</label>
		 					<label class="quarter">
		 						<strong>Assign to :</strong>
		 						<select name="assign_user_id" class="assign_user_id">
		 						    
		 							<option value="1">To Anh</option>
		 							<option value="2">Loc Nguyen</option>
		 						</select>
		 					</label>
		 					<label class="quarter">
		 						<strong>Priority :</strong>
		 						<select name="priority">
		 							<option>Low</option>
		 							<option>Medium</option>
		 							<option>High</option>
		 						</select>
		 					</label>
		 					<label class="quarter bottom">
		 						<button name="save" onClick="add_task(event)" class="save">Save</button>
		 						<a class="cancel" href="#">Cancel	</a>
	 						</label>
	 						</div>
 					</div>
 					</form>
				</td>
			</tr>
		<input type="hidden" name="list_id" class="list_id ${list_id}" value="${list_id}">
		<input type="hidden" name="project_id" class="project_id ${project_id}" value="${project_id}">
		<input type="hidden" name="user_displayname" class="user_displayname ${cur_user_displayname}" value="${cur_user_displayname}">	

			<tr><td colspan="6"><a class="add-new-task" href="#">Add new task</a></td></tr>
		</table>
	</div>
</div>
</script>
